<?php
/**
 *      [迷你云] (C)2009-2012 南京恒为网络科技.
 *   软件仅供研究与学习使用，如需商用，请访问www.miniyun.cn获得授权
 * 
 */
?>
<?php

class FileExif extends CMiniyunModel
{

    public static function model($className=__CLASS__)
    {
        return parent::model($className);
    }

    public function tableName()
    {
        return Yii::app()->params['tablePrefix'].'file_exifs';
    }
    
    public function createFileExif($vertion_id, $lat, $lng, $exif){
        $fileExif = new FileExif();
        $fileExif->version_id = $vertion_id;
        $fileExif->latitude = $lat;
        $fileExif->longtitude = $lng;
        $fileExif->exif = $exif;
        $fileExif->save();
        return $fileExif;
    }
   
      
    function deleteFileExif($version_ids){
    	if($version_ids!='' && strlen($version_ids)>0){
    		 $this->deleteAll("version_id in (".$version_ids.")");
    	}
    }
}